import http from "../utils/request.js";

export const getOrderList = (data) => {
  return http.post(`${import.meta.env.VITE_BASE_URL}/order/order_list`, { ...data });
};

export const exportOrder = () => {
  return http.post(`${import.meta.env.VITE_BASE_URL}/order/export`, {}, { responseType: "blob" });
};

export const updateOrder = (data) => {
  return http.post(`${import.meta.env.VITE_BASE_URL}/order/update`, { ...data });
};

export const deleteOrder = (data) => {
  return http.post(`${import.meta.env.VITE_BASE_URL}/order/delete`, { ...data });
};
